<template>
	<u-navbar v-if="autoHide?platform !== 'h5':true" :is-back="isBack" back-text="返回" :title="title">
		<slot />
		<template v-slot:right>
			<slot name="right" />
		</template>
	</u-navbar>
</template>

<script>
	export default {
		props:{
			isBack:{
				type:Boolean,
				default:()=>false
			},
			title:{
				type:String,
				default:()=>''
			},
			autoHide:{
				type:Boolean,
				default:()=>true
			}
		},
		beforeCreate(){
			this.platform = process.env.VUE_APP_PLATFORM
		}
	}
</script>

<style lang="scss" scoped>
	/deep/ .u-navbar,.u-navbar{
		.u-navbar-inner{
			height: $navbar_height;
		}
	}
</style>
